from base import Blood
from base.meta import Inactive


class PlayerXueBlood(Blood):
    images_1 = "m_xue_tiao.png"

    exist = Inactive(0)

    def move(self, rect, percentage):
        if percentage < 0:
            percentage = 0
        self.area[2] = self.blood_length * percentage
        rect.top -= 5
        rect.left -= 7
        self.rect = rect


class PlayerDiBlood(Blood):
    images_2 = "hong_tiao.png"

    loss = Inactive(0)

    def move(self, rect):
        rect.top -= 5
        rect.left -= 7
        self.rect = rect
